<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<title>OOB</title>
	<script src="../js/jquery-1.8.0.min.js"></script>
		<script type="text/javascript">
			function a(){
				alert(":) |---");
			}
			function b(){
				alert("---| ):");
			}
			window.onload = a;
			/*上面一句是dead code,最终onload指向了b */
			window.onload = b;
			
			//貌似还优先于onload
			$(document).ready(function(){
				alert("ready one");
			})
			$(document).ready(function(){
				alert("ready two");
			})
		</script>
	</head>
	<body>
		<br><a href="../index.jsp">back</a>
		<br><hr color="red" />
		<h5>ready对比window.onload</h5>
	</body>
</html>